package cn.hyatt.auth.dto.auth;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import java.io.Serial;
import java.io.Serializable;

@Getter
@Setter
public class VueRouter implements Serializable {
    @Serial
    private static final long serialVersionUID = 42L;

    @Schema(description = "路由名称")
    private String name;

    @Schema(description = "别名")
    private String alias;

    @Schema(description = "路径")
    private String path;

    @Schema(description = "重定向")
    private String redirect;

    @Schema(description = "组件")
    private String component;

    @Schema(description = "子路由")
    private String children;

    @Schema(description = "附加信息")
    private VueRouterMeta meta;

    // 路由附加信息
    @Getter
    @Setter
    @AllArgsConstructor
    @NoArgsConstructor
    static class VueRouterMeta {
        @Schema(description = "标题")
        private String title;

        @Schema(description = "图标")
        private String icon;
    }
}
